package co.fitstart.entity.user.fit;

import java.math.BigDecimal;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.EnumType;
import javax.persistence.Enumerated;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.Table;

import com.demo2do.core.format.PersistentFormat;
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;

import co.fitstart.entity.reference.Gender;

/**
 * 
 * @author mohanlan
 *
 */
@Entity
@Table(name = "user_shape")
@PersistentFormat
@JsonIgnoreProperties(value={"hibernate_lazy_initializer","handler","fieldHandler"})
public class Shape {
    
    @Id
    @GeneratedValue
    private Long id;
    
    private String name;
    
    @Enumerated(EnumType.ORDINAL)
    private Gender gender;
    
    private String image;
    
    /** 当前体型最小BMI值 */
    @Column(precision = 4, scale = 1)
    private BigDecimal min;
    
    /** 当前体型最大BMI值 */
    @Column(precision = 4, scale = 1)
    private BigDecimal max;
    
    /** SCORE计算的加数 */
    @Column(precision = 4, scale = 1)
    private BigDecimal addenon;
    
    private String methodKey;
    
    public Shape() {
    }

    /**
     * @return the id
     */
    public Long getId() {
        return id;
    }

    /**
     * @return the name
     */
    public String getName() {
        return name;
    }

    /**
     * @return the gender
     */
    public Gender getGender() {
        return gender;
    }

    /**
     * @return the image
     */
    public String getImage() {
        return image;
    }

    /**
     * @return the min
     */
    public BigDecimal getMin() {
        return min;
    }

    /**
     * @return the max
     */
    public BigDecimal getMax() {
        return max;
    }

    /**
     * @return the addenon
     */
    public BigDecimal getAddenon() {
        return addenon;
    }

    /**
     * @return the methodKey
     */
    public String getMethodKey() {
        return methodKey;
    }

    /**
     * @param id the id to set
     */
    public void setId(Long id) {
        this.id = id;
    }

    /**
     * @param name the name to set
     */
    public void setName(String name) {
        this.name = name;
    }

    /**
     * @param gender the gender to set
     */
    public void setGender(Gender gender) {
        this.gender = gender;
    }

    /**
     * @param image the image to set
     */
    public void setImage(String image) {
        this.image = image;
    }

    /**
     * @param min the min to set
     */
    public void setMin(BigDecimal min) {
        this.min = min;
    }

    /**
     * @param max the max to set
     */
    public void setMax(BigDecimal max) {
        this.max = max;
    }

    /**
     * @param addenon the addenon to set
     */
    public void setAddenon(BigDecimal addenon) {
        this.addenon = addenon;
    }

    /**
     * @param methodKey the methodKey to set
     */
    public void setMethodKey(String methodKey) {
        this.methodKey = methodKey;
    }
}
